#ifndef LIBRARY_H
#define LIBRARY_H

#include <string>
#include "Book.h"
#include "BorrowRecord.h"

class Library {
public:
    Library(int capacity);
    ~Library();
    void addBook(const std::string& title, const std::string& author,double price,const std::string& publisher);
    void borrowBook(int bookId, const std::string& borrowerName);
    void returnBook(int bookId);
    void deleteBook(int booId);
    void displayBooks() const;
    void displayBorrowRecords() const;

private:
    static const int MAX_BORROW_RECORDS = 100;
    Book* books;
    BorrowRecord* borrowRecords[MAX_BORROW_RECORDS];
    int capacity;
    int currentBookCount;
    int currentBorrowCount;

    Book* findBookById(int bookId) const;
    BorrowRecord* findBorrowRecordByBookId(int bookId) const;
};

#endif // LIBRARY_H
